package com.itboy.mall.pms.skusaleattrvalue.mapper;

import com.itboy.mall.pms.product.vo.SkuItemSaleAttrVo;
import com.itboy.mall.pms.skusaleattrvalue.domain.MallSkuSaleAttrValue;
import com.itboy.common.core.mybatisplus.core.BaseMapperPlus;
import com.itboy.common.core.mybatisplus.cache.MybatisPlusRedisCache;
import org.apache.ibatis.annotations.CacheNamespace;

import java.util.List;

/**
 * sku销售属性&值Mapper接口
 *
 * @author itboy
 * @date 2021-08-08
 */
// 如使需切换数据源 请勿使用缓存 会造成数据不一致现象
@CacheNamespace(implementation = MybatisPlusRedisCache.class, eviction = MybatisPlusRedisCache.class)
public interface MallSkuSaleAttrValueMapper extends BaseMapperPlus<MallSkuSaleAttrValue> {

	/**
	 * 获取销售属性
	 * @param spuId
	 * @return
	 */
	List<SkuItemSaleAttrVo> getSaleAttrBySpuId(Long spuId);
}
